package api;
import javax.ejb.Local;

import entities.Userprofile;

@Local
public interface IUserDataManager {
	
	public static enum Gender {
		MALE, FEMALE
	}	
	public static enum NotificationApproach {
		ALL, DIGEST
	}
	
	
	boolean updateName(int uid, String name)
		throws InvalidAuthenticationException;
	
	boolean updateAge(int uid,int age)
		throws InvalidAuthenticationException;
	
	boolean updateCity(int uid,String city)
		throws InvalidAuthenticationException;
	
	boolean updateGender(int uid,Gender sex)
		throws InvalidAuthenticationException;
	
	boolean updateEmail(int uid,String email)
		throws InvalidAuthenticationException;
	
	boolean updateNotificationApproach(int uid,NotificationApproach approach, boolean flag)
		throws InvalidAuthenticationException;
	
	Userprofile getProfileById(int uid)
		throws InvalidAuthenticationException;
	
	Userprofile getProfileByUsername(String username) 
		throws InvalidAuthenticationException;

	boolean updatePhoto(int uid, int photoId)
		throws InvalidAuthenticationException;;

}
